<%@ page pageEncoding="UTF-8"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form"%>
<%@ taglib prefix="isperp" uri="/WEB-INF/tlds/isperp.tld"%>
<form:form commandName="model" cssClass="validate"
	action="serviceCatalog/service/save">
	<form:hidden path="id" />
	<div class="header">
		<h2>
			&nbsp;&nbsp;服务产品信息<span><font color="red">（* 为必填项）</font> </span>
		</h2>
	</div>
	<table class=" form-table">
		<tbody>
			<tr>
				<td class="td1">编号：</td>
				<td class="td2"><form:input path="code" maxlength="100"
						cssClass="required" /></td>
			</tr>
			<tr>
				<td class="td1">名称：</td>
				<td class="td2"><form:input path="name" cssClass="required"
						maxlength="200" /></td>
			</tr>
			<tr>
				<td class="td1">分类：</td>
				<td class="td2"><form:input path="categoryId" cssClass="hidden" />
					<isperp:treeSelector id="selectParentDepartment"
						url="serviceCatalog/category/getTree" valueControlId="categoryId"
						displayValue="${categoryName}" displayValueCssClass="required"></isperp:treeSelector>
				</td>
			</tr>
			
			<tr>
				<td class="td1">微信图标（54*54）：</td>
				<td align="left" class="td2"
					style="vertical-align: top;text-align: left;">
					<div style="width:150px;">
						<isperp:photoUploader imgName="photo" cutType="0" imgWidth="54"
							imgHeight="54" imgSrc="${model.photo}" id="photo"
							imgPath="wechat/service_${model.code }" imgFormat="png/gif/jpg"
							showDescription="false"></isperp:photoUploader>
					</div></td>
			</tr>

			<tr>
				<td class="td1">关键字：</td>
				<td class="td2"><form:input path="keyword" maxlength="100"
						cssStyle="width:85%" /></td>
			</tr>
			<tr>
				<td class="td1">服务描述：</td>
				<td class="td2"><form:textarea path="description" />
				</td>
			</tr>
			<tr>
				<td class="td1">服务内容：</td>
				<td class="td2"><form:textarea path="contents" />
				</td>
			</tr>
			<tr>
				<td class="td1">交付物：</td>
				<td class="td2"><form:textarea path="deliverables" />
				</td>
			</tr>
			<tr>
				<td class="td1">服务方式：</td>
				<td class="td2"><form:checkboxes path="serviceWay"
						items="${serviceWay}" itemLabel="name" itemValue="name" /></td>
			</tr>
			<tr>
				<td class="td1">服务响应：</td>
				<td class="td2"><form:checkboxes path="serviceResponse"
						items="${serviceResponse}" itemLabel="name" itemValue="name" /></td>
			</tr>
			
			<tr>
				<td class="td1">标准工时：</td>
				<td class="td2"><form:input  path="standardCost" cssClass="number"/>
				</td>
			</tr>
			<tr>
				<td class="td1">状态：</td>
				<td class="td2"><form:select path="status"
						items="${serviceStatus }" itemLabel="name" itemValue="name" /></td>
			</tr>

		</tbody>
	</table>

</form:form>
<script type="text/javascript">
	isperp.setCheckbox("input[name='serviceWay']", "${model.serviceWay}");
	isperp.setCheckbox("input[name='serviceResponse']", "${model.serviceResponse}");
	isperp.setCheckbox("input[name='pricingModel']", "${model.pricingModel}");
</script>

<isperp:buttonList>
	<button class="submit" onclick="isperp.submitForm();">确认</button>
</isperp:buttonList>